1. Field of the Invention
This invention relates to data processing methods and apparatus.
2. Description of the Prior Art
Some computer-based data processing systems make use of a xe2x80x9ccorexe2x80x9d computer program and a number of possible program modules or xe2x80x9cplug-insxe2x80x9d which can be loaded when required.
Using terminology from the various Microsoft Windows(copyright) operating systems, the program modules or plug-ins may be provided as xe2x80x9cdynamic load librariesxe2x80x9d or xe2x80x9cDLLsxe2x80x9d. DLLs are generally large files which can contain program code, data and subroutine libraries. They are loaded into memory when needed for the execution of a current program.
One example of a data processing system in which this type of structure can be useful is a computer-based video special effects system. In such a system, the user can generally set up a composite special effect to be applied to a video sequence by selecting a succession of effects modules from a large number of available modules. For example, a sequence (or xe2x80x9cdirected acyclic graphxe2x80x9d) of effects set up by a user might comprise:
(i) image loader
(ii) motion tracker
(iii) lighting effect linked to motion tracking and image loader
(iv) image realignment linked to motion tracking and image loader
Each of these effects can be implemented as a program module or plug-in, with data being routed between the modules under the overall control of a core program. In this type of system, those DLLs required to implement the currently selected set of effects are loaded into the computer""s memory when each effect is added to the current composite effect by the user. In this way, DLLs relating to effects modules not part of the current composite effect are not loaded into memory, avoiding a waste of the available memory space.
This invention provides a method of data processing in which a composite data processing operation, for execution by a data processing device having a memory, is assembled by a user as a directed acyclic graph of sub-operations selected from a set of possible data processing sub-operations, the method comprising the steps of:
as a sub-operation is selected by the user for inclusion in the composite operation, loading into the memory sub-operation data defining parameters of that sub-operation including input and output interfaces of that sub-operation; and
in response to an initiation of execution of a sub-operation, loading sub-operation program code into the memory for execution by the data processing device;
in which the sub-operation data requires less memory space than the sub-operation program code.
The invention recognises that in some systems a further memory saving can be achieved over data processing arrangements in which module files such as DLLs are loaded into memory when that module is first selected. In the particular example of a video special effects system, the loading of module files into memory is deferred not only until that effects operation is selected by a user, but even later - until that module has to be run as part of a special effects processing operation. This means that the finite memory of the computer system is used to store the module files for the shortest possible time, so making that memory space available for other uses in the meantime.
The invention achieves this by effectively loading a module file in two stages. In a first stage, a small amount of so-called xe2x80x9cmetadataxe2x80x9d defining the module file, and in particular defining its input and output (i/o) data types and function (method) calls, is loaded into memory. This allows the sequence of operations to be built up in a self-consistent and syntactically correct manner, because the i/o definitions of adjacent modules in the sequence can be matched together using the metadata corresponding to the modules. The actual (much larger) DLLs need be loaded only when finally required to execute the sequence of operations.
The above, and other objects, features and advantages of this invention will be apparent from the following detailed description of illustrative embodiments which is to be read in connection with the accompanying drawings.